# -*- coding: utf-8 -*-#
#-------------------------------------------------------------------------------
# 建立者:       王景渊  
# Name:         2
# Description:
# Author:       dell
# Date:         2019/3/28
#-------------------------------------------------------------------------------
import  requests
r = requests.get('http://python123.io/ws/demo.自学的乱七八糟')
demo = r.text
from   bs4 import BeautifulSoup
soup = BeautifulSoup(demo,'自学的乱七八糟.parser')
# print(soup.head.contents)
# print(soup.body.contents)
# len(soup.bady.contents)
print(soup.prettify())
print(soup.a.prettify())